package com.base.cn.platform.os.service.manage.user.integral;

import com.base.cn.platform.os.entity.user.integral.CusUserIntegralRecord;
import com.base.cn.platform.os.service.FeignAuthConfig;
import com.base.cn.platform.os.service.manage.BaseService;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

/**
 * 积分记录
 */
@FeignClient(value = BaseService.appName,configuration = FeignAuthConfig.class)
public interface CusUserIntegralRecordService extends BaseService {

    /**
     * 搜索积分记录
     * @param currentPage
     * @param cusUserIntegralRecord
     * @return
     */
    @RequestMapping(contextPath + "/user/queryCusUserIntegralRecordListPage")
    Map<String,Object> queryCusUserIntegralRecordListPage(@RequestParam(value = "currentPage", required = false, defaultValue = "1") Integer currentPage,
                                                          @RequestBody CusUserIntegralRecord cusUserIntegralRecord,
                                                          @RequestParam(value = "integralRule", required = false, defaultValue = "false") boolean integralRule);

    /**
     * 搜索积分记录
     * @param containColumns
     * @param cusUserIntegralRecord
     * @return
     */
    @RequestMapping(contextPath + "/user/queryCusUserIntegralRecordList")
    List<Map<String,Object>> queryCusUserIntegralRecordList(@RequestParam(value = "count", required = false) Integer count,
                                                            @RequestParam(value = "containColumns", required = false) List<String> containColumns,
                                                            @RequestBody Map<String, Object> cusUserIntegralRecord,
                                                            @RequestParam(value = "integralRule", required = false, defaultValue = "false") boolean integralRule);


    /**
     * 获取积分统计信息
     * @return
     */
    @RequestMapping(contextPath+"/user/getIntegralStatis")
    Map<String,Object> getIntegralStatis();

}
